package edu.gatech.oad.mule;

import java.io.Serializable;

/**
 * This class represents the map for the game MULE.  A map is any screen-like 
 * interface the players can move around interact.
 *
 * @author Brendan McGarry, Dale Avery, D'Miria Collins, Natasha Parekh, Jaemin Park
 * @version %I%, %G%
 */
public abstract class Map implements Serializable{

	private static final long serialVersionUID = 5240585602758226884L;
	
	//array of zones this map contains.
	//
	//in the case of the world map, it is still a 1D array of zones but
	//  they are handled like a 2D array.  The array can be thought of
	//  like this:
	//
	//  00 01 02 03 04 05 06 07 08
	//  09 10 11 12 13 14 15 16 17
	//  18 19 20 21 22 23 24 25 26
	//  27 28 29 30 31 32 33 34 35
	//  36 37 38 39 40 41 42 43 44
	//
	//In this case, you can figure out which zone a player is standing
	//  on by: floor(player.y/tile.height) * map.width + 
	//  floor(player.x/tile.width).
	//Ex: tiles are 75x75 pixels, the player is at (250, 160), and the map
	//  is 9x5 tiles.  This means the player is at:
	//  floor(160/75) * 9 + floor(250/75)
	//  = 2*9 + 3
	//  = 21
	//
	//For the town map, this represents the interactive areas on the map
	//  (the buildings)
	protected Zone[] zoneGrid;

	public abstract Zone getCollidedZone(Player p);

}//end class Map
